﻿using System;
using System.Collections.Generic;
using Newtonsoft.Json;
using Pay.TO;

namespace Pay.DTO {
	/// <summary>
	/// 支付方式
	/// </summary>
	[Serializable]
	[JsonObject(MemberSerialization.OptOut)]
	public class payment_dto {
		public payment_dto() {
			settles = new List<settle_setting>();
			bank = new List<use_bank>();
		}
		/// <summary>
		/// 支付方式
		/// </summary>
		public long id { get; set; }
		/// <summary>
		/// 签约通道的商户id
		/// </summary>
		public long merchant_id { get; set; }
		/// <summary>
		/// 通道
		/// </summary>
		public PayChannel channel { get; set; }
		/// <summary>
		/// 支付名称
		/// </summary>
		public string name { get; set; }
		/// <summary>
		/// 结算方式
		/// </summary>
		public List<settle_setting> settles { get; set; }
		/// <summary>
		/// 可用银行[{"name":"","code":""}]
		/// </summary>
		public List<use_bank> bank { get; set; }
		/// <summary>
		/// 开始时间
		/// </summary>
		public int start_time { get; set; }
		/// <summary>
		/// 结束时间
		/// </summary>
		public int end_time { get; set; }
		/// <summary>
		/// 单笔额度,0不限
		/// </summary>
		public decimal single_quota { get; set; }
		/// <summary>
		/// 单卡额度/天,0不限
		/// </summary>
		public decimal card_quota { get; set; }
		/// <summary>
		/// 是否关闭
		/// </summary>
		public bool is_open { get; set; }
		/// <summary>
		/// 是否要进件
		/// </summary>
		public bool is_register { get; set; }
		/// <summary>
		/// 是否可以进件多次
		/// </summary>
		public bool is_more { get; set; }
	}

	/// <summary>
	/// 可支付银行
	/// </summary>
	[Serializable]
	public class use_bank {
		/// <summary>
		/// 银行名称
		/// </summary>
		public string name { get; set; }
		/// <summary>
		/// 银行编号
		/// </summary>
		public string code { get; set; }
	}
}